Conversation
| "path": "path/to/level", | ||
| "scheme": "nested" | ||
| "scheme": "nested", | ||
| "naming": "react" |
There was a problem hiding this comment.
can I define scheme and naming on the top near the root-prop? Simple example "I want to define react-naming to all my levels"
There was a problem hiding this comment.
oh, i misunderstood your idea.
let's doublecheck it again.
for following file structure:
parent-dir/
.bemrc # root: true here
project-cwd/
.bemrc
and
// parent-dir/.bemrc
{
"root": true,
"levels": [
{
"path": "path/to/level",
"scheme": "nested",
"naming": "react"
}
]
}
// parent-dir/project-cwd/.bemrc
{
"levels": [
{
"path": "path/to/level",
"scheme": "nested"
}
]
}run
require('@bem/sdk.config')().levelSync('path/to/level'); // { scheme: 'nested', naming: 'react' }isn't it exactly what you need?
There was a problem hiding this comment.
Mmm. levelSync takes path not layer. My bad, sorry
There was a problem hiding this comment.
Will you add naming/scheme props on the top level of config like:
{
"root": true,
"naming": "react",
"levels": ...
}?
There was a problem hiding this comment.
It works as you wish right now (any option from root level will be available in levelSync() output). The reason I don't want it in example in readme is that each level can actually have its own naming scheme.
There was a problem hiding this comment.
I understand but specifying naming on top is very common. So I propose to add it in example
|
@tadatuta lets finish this :) |
No description provided.